Skip to content

Add release notes agentic workflow#10334

Merged
richlander merged 67 commits intomainfrom
release-notes-agentic-workflow
Apr 6, 2026
Merged

Add release notes agentic workflow#10334
richlander merged 67 commits intomainfrom
release-notes-agentic-workflow

Conversation

@richlander
Copy link
Copy Markdown
Member

@richlander richlander commented Apr 1, 2026

Summary

Adds an agentic workflow that automatically generates and maintains .NET release notes by analyzing the VMR (dotnet/dotnet) source-manifest diffs. Changes.json (complete list of commits and PRs) is another generated artifact that can be used in other works. Is largely schema-compatible with cve.json.

Architecture (3 layers)

  1. dotnet-release tool (deterministic) — diffs src/source-manifest.json between release refs to produce changes.json, a comprehensive manifest of every PR that shipped
  2. AI agent (editorial) — reads changes.json and writes curated markdown release notes, guided by reference docs in .github/skills/release-notes/references/
  3. Agentic workflow (orchestration) — runs nightly, manages branch lifecycle, respects human edits, responds to PR comments

Key capabilities

  • Multi-milestone — discovers all active milestones (e.g., Preview 4 and Preview 5 simultaneously) and creates a branch + PR for each
  • Nightly re-validation — base/head refs are re-checked every run as VMR tags appear, release branches are created, and main bumps
  • Human-in-the-loop — respects edits on branches, reads and responds to PR comments, asks when unsure
  • Deterministic milestone detection — 3-signal algorithm using releases.json, VMR Versions.props, and VMR tags

Files

Path Purpose
.github/workflows/release-notes.md Agentic workflow definition
.github/workflows/release-notes.lock.yml Compiled workflow (generated)
.github/skills/release-notes/DESIGN.md System design document
.github/skills/release-notes/SKILL.md Skill metadata
.github/skills/release-notes/references/*.md Reference docs (schema, templates, editorial rules, etc.)

Testing

  • Tested dotnet-release generate changes (P1→P2: 1,389 changes; P2→P3: 2,259 changes)
  • Tested milestone detection algorithm against live VMR state
  • Full E2E test: generated all component markdown files from changes.json
  • Compiled workflow with gh aw compile — passes validation

Dependencies

  • dotnet-release v2.0.0+ (the generate changes command)
  • GitHub Agentic Workflows runtime

richlander and others added 30 commits March 26, 2026 16:22
Cron-driven GitHub Agentic Workflow that maintains release notes
branches for .NET preview/RC/GA releases. Architecture:

- dotnet-release generate changes tool produces changes.json
  (deterministic, from VMR source-manifest.json diffs)
- Agent reads changes.json and writes curated markdown for
  high-value features
- One PR per release milestone, maintained incrementally
- Respects human edits on the branch

Skill references (6 docs, ~700 lines total):
- quality-bar.md: what good release notes look like
- vmr-structure.md: VMR branches, tags, source-manifest.json
- changes-schema.md: changes.json schema reference
- component-mapping.md: components, product slugs, output files
- format-template.md: markdown document structure
- editorial-rules.md: tone, attribution, naming

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Describes the three-layer architecture (tool → agent → workflow),
the source-manifest.json mechanism, branch lifecycle, and design
rationale. Links from SKILL.md for discoverability.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Tested dotnet-release v1.1.0 generate changes against the VMR
(P1→P2: 1,389 changes across 21 repos). Updated docs to reflect
the actual tool output:

- Remove aspirational product/package fields from changes-schema.md
  (tool outputs repo, not product slugs)
- Add labels field (optional, via --labels flag)
- Fix workflow CLI syntax (positional path, --base/--head)
- Update component-mapping.md: agent does repo→file routing
- Remove resolved open question about package mapping
- Update example JSON and jq queries to match real output

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
vstest is the only microsoft org repo in the VMR manifest and is
already on the infra skip list. SAML token requirements for the
microsoft org can be addressed later.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Tested --labels flag: 776/1389 changes got labels (56% coverage).
Best coverage: runtime (94%), roslyn (96%), winforms/wpf (100%).
Lower coverage on infra-heavy repos as expected.

Corrected the schema docs — the product field IS output by the
tool (repo-level mapping), just empty for infra repos. Added
product back to the schema with accurate description. Added
labels field documentation and updated examples/queries.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replace heuristic branch-scanning with a deterministic algorithm
using three data sources:
1. releases.json → what has shipped
2. VMR eng/Versions.props on main → current development iteration
3. VMR tags → base refs for generating diffs

Decision: if Versions.props iteration > latest shipped → that's
the target. Exact commands provided in workflow steps 1-2.

Updated DESIGN.md (milestone detection section), vmr-structure.md
(version metadata + base tag discovery), and the workflow file
(deterministic steps 1 and 2 with concrete examples).

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Once main is bumped to the next iteration, it contains preview N+1
work. The agent must check if a VMR tag exists for the target
milestone:
- No tag → in development, use --head main
- Tag exists → finalized, use --head <tag>

Updated workflow step 1e and step 2 with both code paths.
Added Head ref selection section to DESIGN.md explaining why
this matters.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The general 'What'\''s new in .NET' link belongs in README.md, not
in every component file. Component files should link to their
specific docs page when one exists (runtime, libraries, SDK,
ASP.NET Core, C#, EF Core).

Added the dotnet/docs overview source URL so the agent can
discover component-specific links.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
v1.2.0 now maps every source-repo change to its VMR codeflow
commit. The new dotnet_commit field on each change entry keys
into the commits dict for the dotnet/dotnet commit. Multiple
source PRs typically share the same VMR commit (codeflow batches).

Updated schema docs, example JSON, and field descriptions.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- commit field is now VMR commit (was source repo)
- dotnet_commit removed (replaced by commit)
- local_repo_commit added for source repo commit
- product field absent for infra repos (not empty string)
- Updated example and jq queries

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Multi-milestone: discover all active milestones (P4 and P5 simultaneously)
- Re-validate base/head refs every nightly run (tags appear, branches create, main bumps)
- Branch-per-milestone on dotnet/core (release-notes/11.0-preview4, etc.)
- Human interaction: respect edits, respond to PR comments, ask when unsure
- Handle transitions: main bumps, new tags, release branches, PR merges
- Increased safe-output limits for multi-milestone support
- Updated DESIGN.md with multi-milestone discovery, human interaction model

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Fix invalid toolsets: contents→repos, code_search→search
- Add compiled release-notes.lock.yml
- Add .github/aw/actions-lock.json (gh aw artifact)
- Add linguist-generated gitattributes for lock files

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The inline example in this file is the authoritative reference.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Six examples from .NET 9/10 preview release notes demonstrating three styles:
- Short: exception handler diagnostics, container insecure registries
- Medium: extension operators (C#), PipeReader JSON support
- Long: post-quantum cryptography, OpenIdConnect PAR

Added to reference docs list in workflow and DESIGN.md.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Three styles of JIT feature descriptions:
- Array Enumeration De-Abstraction (progressive benchmarks, optimization narrative)
- Struct Arguments codegen (before/after assembly comparison)
- Loop Optimizations (metric-heavy prose, no code)

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The agent should recognize when a feature description needs content it
can't generate (benchmark data, definitive code samples, domain expertise)
and post PR comments requesting it from feature authors.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replace monolithic examples.md with per-component files:
- examples/README.md — principles index, component directory
- examples/runtime.md — 3 JIT examples with inlined content
- examples/aspnetcore.md — 3 examples (short/medium/long)
- examples/csharp.md — extension operators
- examples/sdk.md — container insecure registries
- examples/libraries.md — post-quantum cryptography

Each file includes the actual example text and links back to
the original source file. Agent loads only the relevant component
file when writing, saving context tokens.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
New format per file:
  ## Heading (H2)
  Actual content (copy/paste from original)
  ---
  Source: link to original
  Commentary: why it was selected
  Why it works: what makes it effective
  ---

Clear separation between the example content and the editorial
commentary. Content reads exactly as it would in release notes.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- id field is now string (repo@commit format) — globally unique
- Updated schema docs and example JSON
- Removed trailing blank lines in example metadata blocks

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
More frequent runs mean faster feedback loops on PR comments
and quicker pickup of new VMR content.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replaces SuppressDiagnosticsCallback (prose-only) with StatusCodeSelector
(one paragraph + clean code sample). Better exemplar for 'short + code'.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The 'guest introduction' style restructures the note around attribution
instead of the feature. Prefer: explain the feature, then credit at end.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
'Snippet' in a programming context suggests code. Say what you mean plainly.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copy link
Copy Markdown
Member

@jeffhandley jeffhandley left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@richlander I merged main and went ahead and applied all of my feedback with a series of commits. Feel free to unwind them and force push if you'd like but I figured pushing the commits was a more efficient way of submitting all of my feedback.

I'm running the workflow on my fork now (run) and I'd like to review the results that are generated before hitting approve, but if the results match what we're looking for the implementation looks all right.

The aspects I'm particularly going to be looking for in the produced results are:

  • How does it do for libraries without directly referencing the API Diff? Presumably dotnet-inspect is going to substitute that but the api diff reports are a dense diff format that seemed to be ideal for getting the API changes into context.
  • Taking the dependency on external tools/repos for gathering the changes. Ideally that would all be self-contained, IMHO; but I understand those tools are still evolving and this is a good test bed for them as well.
  • Not having component-specific references for teams to provide component-specific guidance into the data gathering and authoring. I understand what you're after here though and we can add that back in if needed.

There are some places where the workflow, skill, and the design doc repeat statements/content/logic. In the commits I pushed, I dialed some of that back a little but there is still repeated statements across those pieces of content that will be prone to drift over time. For example, the schedule info was repeated across several places and it was inconsistent. I updated those references for consistency and to reduce the "sources of truth" of the info--including updating the cron schedule to be daily ~ 9am PDT instead of every 6 hours.

Also with my commits, I integrated the select-copilot-pat logic that allows us to have a pool of PATs to draw from instead of relying on one person's PAT. I did the initial setup of that so the workflow will run. I removed the Open Question about the PAT/scope that you had as this addresses that topic.

3. **Queries GitHub compare API** for each changed component to enumerate merged PRs in the commit range
4. **Maps repos to product slugs** using a built-in taxonomy (e.g., `runtime` → `dotnet-runtime`; infra repos get no product)
5. **Fetches PR labels** when `--labels` is provided (useful for agent categorization)
6. **Cross-references CVEs** when `--cve-repo` is provided (loads `cve.json` from the `release-index` branch)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm curious how you intend to reference CVE info giving the timing of the CVE publications, security fixes, and the authoring of release notes. I didn't expect to see any security- or CVE-related topics in this skill/workflow.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This doesn't apply to previews. For servicing releases, this system will likely be run behind the firewall.

@jeffhandley
Copy link
Copy Markdown
Member

Edge case testing, but on my fork I deleted the preview-2 release notes so I could regenerate them with this implementation and compare the output to what we publsihed. The workflow ended up failing.

https://github.com/jeffhandley/dotnet-core/actions/runs/23938625467/job/69820753316#step:9:115

Error: ✗ Message 1 (push_to_pull_request_branch) failed: push-to-pull-request-branch with target "triggering" requires pull request context
Warning: ⚠️ Code push operation 'push_to_pull_request_branch' failed — remaining safe outputs will be cancelled

jeffhandley and others added 5 commits April 3, 2026 17:06
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copy link
Copy Markdown
Member

@jeffhandley jeffhandley left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Still reading but sharing some comments while I make progress.

```

Set an initial wait of at least 300 seconds — the script takes several minutes. Use `read_powershell` to poll for completion. The script does not print a final "done" message; it exits after generating a README.md in the output folder. After completion, summarize the results: how many diff files were generated and where.
Set an initial wait of at least 300 seconds — the script takes several minutes. After completion, summarize the results: how many diff files were generated and where.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Curious why you're removing this sentence. I had added it after the agent kept tripping up on how to consume the output from the tool, and this made it more reliable.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That seems like overfit. Did you find that the agent needs that information?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure if this file needs to be committed or if we should just include this as a comment on the PR.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@richlander richlander force-pushed the release-notes-agentic-workflow branch from 12a40b4 to 9242e31 Compare April 6, 2026 22:42
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copy link
Copy Markdown
Member

@jeffhandley jeffhandley left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a few additional comments; approving for when those are addressed. Thanks for all the effort on this!

richlander and others added 5 commits April 6, 2026 16:21
Co-authored-by: Jeff Handley <jeffhandley@users.noreply.github.com>
Co-authored-by: Jeff Handley <jeffhandley@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Update the workflow docs, repo skills, and locked workflow permissions to use the renamed maintainer CLI and package name while keeping dotnet-release for the public graph-query tool.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@richlander richlander merged commit 3dfeeca into main Apr 6, 2026
6 of 8 checks passed
@richlander richlander deleted the release-notes-agentic-workflow branch April 6, 2026 23:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants